using System.Collections.Generic;
using System.Linq;
using QFramework;
using UnityEngine;

public class ProgressSystem : AbstractSystem
{
    public List<StageData> StageProgress;
    private string path = "Config/StageConfig";
    protected override void OnInit()
    {
        StageProgress = Resources.LoadAll<StageData>(path).ToList();
        StageProgress.Sort((a, b) => a.Index.CompareTo(b.Index));
    }
    protected override void OnDeinit()
    {
        foreach (var item in StageProgress)
        {
            item.IsFinish = false;
            item.NeedChange2Win = false;
        }
    }
}